/**
 * @file shotclock.h
 * @brief Independent basketball shot clock (24/14 seconds) subsystem
 */

#ifndef CATIME_SHOTCLOCK_H
#define CATIME_SHOTCLOCK_H

#include <windows.h>

/**
 * @brief Initialize shot clock module from config (reads defaults)
 */
void ShotClock_InitFromConfig(void);

/**
 * @brief Ensure shot clock window exists and show it
 */
void ShotClock_ShowWindow(void);

/**
 * @brief Hide shot clock window if visible
 */
void ShotClock_HideWindow(void);

/**
 * @brief Toggle shot clock window visibility
 */
void ShotClock_ToggleVisibility(void);

/**
 * @brief Start counting down from current remaining time
 */
void ShotClock_Start(void);

/**
 * @brief Pause counting down (retains remaining time)
 */
void ShotClock_Pause(void);

/**
 * @brief Resume counting down
 */
void ShotClock_Resume(void);

/**
 * @brief Reset to primary setting (typically 24 seconds)
 */
void ShotClock_ResetPrimary(void);

/**
 * @brief Reset to secondary setting (typically 14 seconds)
 */
void ShotClock_ResetSecondary(void);

/**
 * @brief Check if shot clock window is visible
 */
BOOL ShotClock_IsVisible(void);

/**
 * @brief Query if shot clock is currently running
 */
BOOL ShotClock_IsRunning(void);

/**
 * @brief Get shot clock window handle (NULL if not created)
 */
HWND ShotClock_GetHwnd(void);

/**
 * @brief Get configured primary reset seconds (fallback to 24 if unset)
 */
int ShotClock_GetPrimaryResetSeconds(void);

/**
 * @brief Get configured secondary reset seconds (fallback to 14 if unset)
 */
int ShotClock_GetSecondaryResetSeconds(void);

#endif /* CATIME_SHOTCLOCK_H */